# RESTAT Code and Data Submission

This repository holds the programming code and data files for replicating the results in the article "Motivating Innovation: The Effect of Loss Aversion on the Willingness to Persist" by Yaroslav Rosokha & Kenneth Younge.

	Yaroslav Rosokha   
	Krannert School of Management  
	Purdue University  
	Email: yrosokha@purdue.edu   
	
	Kenneth Younge  
	Ecole Polytechnique Federale de Lausanne  
	Email: kenneth.younge@epfl.ch  


## Folders

### experiments/

Raw CSV files for the results from each of the human subject experiments.  

### sims/

Raw CSV files for the simulation results from the Q-learning simulation experiments.  

### data/

Intermediate data files generated from the raw experimental data and used to calculate results in the paper. 

### results/

Output from running the code files listed below.


## Programming Code

All of the analysis for the article can be replicated by executing the following 10 files in a sequential progression. Each file is entirely self-contained and should execute in a stand-alone manner.

	01_graph_avg_exploration_fig_4.py
	02_calc_descriptive_stats_table_3.py
	03_calc_results_table_4.py
	04_calc_net_benefit.py
	05_graph_net_benefit_figure_5.R
	06_regress_table_5.do
	07_match_samples.py
	08_regress_table_6.do
	09_run_simulations.py
	10_graph_avg_exploration_sims_fig_7.py


